//
//  Animation.h
//  Void Dead
//
//  Created by Sidney Just on 08.07.09.
//  Copyright 2009 by Sidney Just.
//  This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; 
//  either version 3 of the License, or (at your option) any later version.
//  
//  This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty 
//  of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
//  

#import <Foundation/Foundation.h>
#import <OpenGLES/ES1/gl.h>

/**
 * This class allows to crate a animation for a panel
 * You normally don't create a object of this class per hand becaus they won't be calculated by the panelmanager
 **/

@interface VD_Animation : NSObject {
	float animationStart;
	float animationEnd;
	float animationTileSize;
	float animationLeap;
	
	float animationSpeed;
	float animationStep;
	
	GLfloat atlasPos;
	GLfloat atlasSize;
}

/**
 * The time since the last animation frame in seconds
 **/
@property float animationStep;

/**
 * The time that's needed to change the animation frame in seconds
 **/
@property float animationSpeed;

/**
 * Start point of the animation in texture coordinates
 **/
@property float animationStart;

/**
 * End point of the animation in texture coordinates
 **/
@property float animationEnd;

/**
 * The size of on tile in texture coordinates
 **/
@property float animationTileSize;

/**
 * The tiles that get leaped per animation frame
 **/
@property float animationLeap;

/**
 * Position of the atlas
 **/
@property GLfloat atlasPos;

/**
 * Size of the atlas
 **/
@property GLfloat atlasSize;

@end
